package system

import (
	"github.com/gogf/gf/v2/frame/g"
)

type LoginReq struct {
	g.Meta   `path:"/system/admin/login" tags:"系统管理-登录" method:"post" summary:"登录" description:"使用账号密码进行"`
	Username string `v:"required" dc:"用户账户名"`
	Password string `v:"required" dc:"密码"`
}
type LoginRes struct {
	Token string `json:"token" dc:""`
}

type PhoneLoginReq struct {
	g.Meta `path:"/system/admin/phoneLogin" tags:"系统管理-登录" method:"post" summary:"手机号验证码登录" description:"手机号验证码登录"`
	Phone  string `v:"required" dc:"手机号"`
	Code   string `v:"required" dc:"验证码"`
}
type PhoneLoginRes struct {
	Token string `json:"token" dc:""`
}

type LogoutReq struct {
	g.Meta `path:"/system/admin/logout" tags:"系统管理-登录" method:"post" summary:"退出" description:"退出系统登录"`
}
type LogoutRes struct {
}

type WebsocketReq struct {
	g.Meta `path:"/system/admin/websocket" tags:"系统管理-登录" method:"post" summary:"获取连接websocket的URL" description:"获取连接websocket的URL"`
}
type WebsocketRes struct {
	URL string `json:"url" dc:"连接websocket的url"`
}
